package com.summer.main;

public class ExtendsTest {
	
//	public class A{
//		public Integer getLength(){
//			return new Integer(4);
//		}
//	}
//	
//	public class B extends A{
////		public Long getLength(){
////			return new Long(5);
////		}
//	}
//	
	public static void main(String[] args) {
		System.out.println("url_v3_0="+Url.V3.getAll);
		System.out.println("url_v3_1="+Url.V3.getAll1);
		System.out.println("url_v3_2="+Url.V3.getAll2);
		System.out.println("url_v3_3="+Url.V3.getAll3);
		System.out.println("----------------------------------------------------");
		
		System.out.println("url_v4_0="+Url.V4.getAll);
		System.out.println("url_v4_1="+Url.V4.getAll1);
		System.out.println("url_v4_2="+Url.V4.getAll2);
		System.out.println("url_v4_3="+Url.V4.getAll3);
		System.out.println("url_v4_4="+Url.V4.getAll4);
		System.out.println("----------------------------------------------------");
		System.out.println("url_Cur_0="+Url.Cur.getAll);
		System.out.println("url_Cur_1="+Url.Cur.getAll1);
		System.out.println("url_Cur_2="+Url.Cur.getAll2);
		System.out.println("url_Cur_3="+Url.Cur.getAll3);
		System.out.println("url_Cur_4="+Url.Cur.getAll4);
//
//		System.out.println("url_v3="+Url.v3.getAll);
//		System.out.println("url_v3="+Url.v3.getAll1);
//		System.out.println("url_v3="+Url.v3.getAll2);
//		System.out.println("url_v4="+Url.v4.getAll);
//		System.out.println("url_v4="+Url.v4.getAll1);
//		System.out.println("url_v4="+Url.v4.getAll2);
//		System.out.println("url_cur="+Url.cur.getAll);
//		System.out.println("url_cur="+Url.cur.getAll1);
//		System.out.println("url_cur="+Url.cur.getAll2);
	}
	
	public static class Url{
		
		public final static Url cur = new V3();
		public final static Url v3 = new V3();
		public final static Url v4 = new V4();
		
		protected static String var(){
			return "url";
		};
		
		public static final String getAll = var() + "-123";
		public static final String getAll1 = var() + "-123";
		public static final String getAll2 = var() + "-123";
		

		public static class V3 extends Url{
			protected static String var(){
				return "v3";
			};
			public static final String getAll1 = var() + "-123";
			public static final String getAll3 = var() + "-123";
		}
		
		public static class V4 extends V3{
			protected static String var(){
				return "v4";
			};
			public static final String getAll2 = var() + "-123";
			public static final String getAll4 = var() + "-123";
		}
		
		public static class Cur extends V4{}
	}
}
